<?php
require_once('Zend/Controller/Front.php');
$main = Zend_Controller_Front::getInstance();

$plugdir = opendir("../plugins");

while ($plugin = readdir($plugdir))
{
	if ($plugin != '..' && $plugin != '.' && !preg_match('/^\..*/', $plugin) && !preg_match('/.php.LCK/', $plugin))
	{	
		$plugin = str_replace(".php", "", $plugin);
		$main->registerPlugin(new $plugin);
	}
}
